home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Pascal Super Library
/
Pascal Super Library (CW International)(1997).bin
/
LIBRARY
/
PTRP10
/
TEST12.TRP
< prev
next >
Wrap
Text File
|
1994-05-16
|
568b
|
28 lines
procedure main;
var
n : longint;
endvar
global
p : longint;
endvar
write("Enter Value : ")
readln(n);
writeln("n = ", n);
calcIt(n);
writeln("2 * n = ", p)
writeln('4 * n = ', retTest(n))
writeln('10* n = ', funcAssignTest(n))
endproc
function calcIt(a : longint) : longint;
p := 2 * a;
endproc
function retTest(a : longint) : longint;
return 4 * a;
endproc
function funcAssignTest(a : longint) : longint;
funcAssignTest := 10 * a;
endproc